package Beans;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

/**
 * 包裹信息
 * 
 * @author wjm
 * 
 */
@Entity
@Table(name = "packageinfo")
public class PackageInfo {
	private int id; // 编号
	private String consignorName; // 包裹寄件人姓名
	private String consignorAddr; // 包裹寄件人地址
	private String consignorPhoneNum;// 包裹寄件人联系号码
	private String consigneeName;// 包裹收件人姓名
	private String consigneeAddr;// 包裹收件人地址
	private String consigneePhoneNum;// 包裹收件人联系号码
	private String packNum; // 包裹单号
	private float weight;// 包裹重量
	private String companyName;// 包裹所在公司名称
	private String status;// 包裹状态
	private String comment;// 包裹备注

	@GenericGenerator(name = "generator", strategy = "native")
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "packageInfo_id", unique = true, nullable = false)
	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	@Column(name = "packageInfo_consignorName")
	public String getConsignorName() {
		return consignorName;
	}

	public void setConsignorName(String consignorName) {
		this.consignorName = consignorName;
	}

	@Column(name = "packageInfo_consignorAddr")
	public String getConsignorAddr() {
		return consignorAddr;
	}

	public void setConsignorAddr(String consignorAddr) {
		this.consignorAddr = consignorAddr;
	}

	@Column(name = "packageInfo_consignorPhoneNum")
	public String getConsignorPhoneNum() {
		return consignorPhoneNum;
	}

	public void setConsignorPhoneNum(String consignorPhoneNum) {
		this.consignorPhoneNum = consignorPhoneNum;
	}

	@Column(name = "packageInfo_consigneeName")
	public String getConsigneeName() {
		return consigneeName;
	}

	public void setConsigneeName(String consigneeName) {
		this.consigneeName = consigneeName;
	}

	@Column(name = "packageInfo_consigneeAddr")
	public String getConsigneeAddr() {
		return consigneeAddr;
	}

	public void setConsigneeAddr(String consigneeAddr) {
		this.consigneeAddr = consigneeAddr;
	}

	@Column(name = "packageInfo_consigneePhoneNum")
	public String getConsigneePhoneNum() {
		return consigneePhoneNum;
	}

	public void setConsigneePhoneNum(String consigneePhoneNum) {
		this.consigneePhoneNum = consigneePhoneNum;
	}

	@Column(name = "packageInfo_packNum")
	public String getPackNum() {
		return packNum;
	}

	public void setPackNum(String packNum) {
		this.packNum = packNum;
	}

	@Column(name = "packageInfo_weight")
	public float getWeight() {
		return weight;
	}

	public void setWeight(float weight) {
		this.weight = weight;
	}

	@Column(name = "packageInfo_CompanyName")
	public String getCompanyName() {
		return companyName;
	}

	public void setCompanyName(String companyName) {
		this.companyName = companyName;
	}

	@Column(name = "packageInfo_status")
	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	@Column(name = "packageInfo_comment")
	public String getComment() {
		return comment;
	}

	public void setComment(String comment) {
		this.comment = comment;
	}

	public PackageInfo() {

	}

	/**
	 * 包裹信息
	 * 
	 * @param consignorName
	 *            包裹寄件人姓名
	 * @param consignorAddr
	 *            包裹寄件人地址
	 * @param consignorPhoneNum
	 *            包裹寄件人联系号码
	 * @param consigneeName
	 *            包裹收件人姓名
	 * @param consigneeAddr
	 *            包裹收件人地址
	 * @param consigneePhoneNum
	 *            包裹收件人联系号码
	 * @param packNum
	 *            包裹单号
	 * @param weight
	 *            包裹重量
	 * @param companyName
	 *            包裹所在公司名称
	 * @param status
	 *            包裹状态
	 * @param comment
	 *            包裹备注
	 */
	public PackageInfo(String consignorName, String consignorAddr,
			String consignorPhoneNum, String consigneeName,
			String consigneeAddr, String consigneePhoneNum, String packNum,
			float weight, String companyName, String status, String comment) {
		super();
		this.consignorName = consignorName;
		this.consignorAddr = consignorAddr;
		this.consignorPhoneNum = consignorPhoneNum;
		this.consigneeName = consigneeName;
		this.consigneeAddr = consigneeAddr;
		this.consigneePhoneNum = consigneePhoneNum;
		this.packNum = packNum;
		this.weight = weight;
		this.companyName = companyName;
		this.status = status;
		this.comment = comment;
	}

}
